#include "../source/Server.hpp"

int main()
{
    Socket client;
    client.CreateClient(8080,"127.0.0.1");
    // while(true){
    //     std::string info = "for test socket";
    //     client.Send(info.c_str(),info.size());    
    //     char buffer[1024] = {0};
    //     client.Recv(buffer,1023);
    //     DBG_LOG("%s",buffer);
    //     // sleep(1);
    // }
    for (int i = 0; i < 5; i++){
        std::string info = "for test socket";
        auto ret = client.Send(info.c_str(),info.size());    
        char buffer[1024] = {0};
        auto ret1 = client.Recv(buffer,1023);
        DBG_LOG("%s",buffer);
        sleep(1);
    }
    while(1) sleep(1);
    return 0;
}